﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.ServiceModel;
using System.Text;
using System.ServiceModel.Web;
using PiscoSourDominio;

namespace PiscoSourRESTServices
{
    // NOTE: You can use the "Rename" command on the "Refactor" menu to change the interface name "IClientes" in both code and config file together.
    [ServiceContract]
    public interface IClientes
    {
        [OperationContract]
        [WebInvoke(Method = "POST", UriTemplate = "UCliente/{codigo}/{pass}", ResponseFormat = WebMessageFormat.Json)]
        Cliente ObtieneUsuarioCliente(string codigo, string pass);

        [OperationContract]
        [WebInvoke(Method = "POST", UriTemplate = "Cliente", ResponseFormat = WebMessageFormat.Json)]
        Cliente ObtenerCliente(int codigo);

        [OperationContract]
        [WebInvoke(Method = "GET", UriTemplate = "ListaClientes", ResponseFormat = WebMessageFormat.Json)]
        List<Cliente> ListaClientes();

        [OperationContract]
        [WebInvoke(Method = "GET", UriTemplate = "ListaClientesIna", ResponseFormat = WebMessageFormat.Json)]
        List<Cliente> ListaClientesInactivos();

        [OperationContract]
        [WebInvoke(Method = "GET", UriTemplate = "ValidaCliente/{login}/{pass}", ResponseFormat = WebMessageFormat.Json)]
        Cliente ValidarLogin(string login, string pass);
    }
}
